/**
 * RequestPageInfo.java
 * com.aabill.api
 *
 * Function： TODO 
 *
 *   ver     date      		author
 * ──────────────────────────────────
 *   		 2012-8-14 		wangjieming
 *
 * Copyright (c) 2012, TNT All Rights Reserved.
 */

package com.jamin.aabill.api;

import org.json.JSONException;
import org.json.JSONObject;

/**
 * ClassName:RequestPageInfo
 *
 * @author   wangjieming
 * @version  1.0
 * @since    v1.0
 * @Date	 2012-8-14 上午8:19:49 
 */
public class RequestPageInfo extends JsonResponse{


	
	public RequestPageInfo(JSONObject jsonStr){
		try {
			JSONObject jsonObj = jsonStr.getJSONObject("page_info");
			cur_page = getInt("cur_page", jsonObj);
			page_size = getInt("page_size", jsonObj);
			total_items = getInt("total_items", jsonObj);
		} catch (JSONException e) {
		}
	}


	int cur_page;                //当前页面号
	int page_size;               //每页大小
	int total_items;             //总信息条目数


	public int getCur_page() {
		return cur_page;
	}
	public void setCur_page(int cur_page) {
		this.cur_page = cur_page;
	}
	public int getPage_size() {
		return page_size;
	}
	public void setPage_size(int page_size) {
		this.page_size = page_size;
	}
	public int getTotal_items() {
		return total_items;
	}
	public void setTotal_items(int total_items) {
		this.total_items = total_items;
	}

	@Override
	public String toString() {

		return "RequestPageInfo:{ " +
				"cur_page = '"+ cur_page + "\'" + "," + 
				"page_size = '"+ page_size + "\'" + "," +
				"total_items = '"+ total_items + "\'" + "," +
				"}"; 
	}


}

